import { createApp } from 'vue'
import App from '@/App.vue'
import router from '@/router'
import 'element-plus/dist/index.css'
import '@/assets/css/animate.css'
import "@/assets/css"
import { formatDate } from '@vueuse/core'
import { setRequestInstance } from "@usehook/useRequest"
import request from "@/utils/request"

setRequestInstance(request)
const app = createApp(App)
app.use(router)

Date.prototype.format = function (fmt) {
    return formatDate(this, fmt)
}

String.prototype.rsplit = function (sep, maxsplit) {
    var split = this.split(sep);
    return maxsplit ? [split.slice(0, -maxsplit).join(sep)].concat(split.slice(-maxsplit)) : split;
}

app.mount('#app')
